<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="jquery.min.js"></script>
</head>
<body>

</body>

<script>

    var arr = [1, 3, 5, 7, 9];
    // 伪数组
    var obj = {0: 1, 1: 3, 2: 5, 3: 7, 4: 9, length: 5}

    // 原生的js 遍历
    arr.forEach(function (value, index) {
        console.log(index, value);
    })


    arr.map(function (value, index, array) {
        console.log(index, value, array);

    })


    // jquery 遍历
    $.each(arr, function (index, value) {
        console.log(index, value);
    })


    $.map(arr, function (value, index) {
        console.log(index, value);
    })
</script>
</html>